<template>
  <div class="sona">
    <button @click="btnClick">传值 给sonb</button>
  </div>
</template>
<script>
import bus from '@/utils/bus'
export default {
  methods: {
    btnClick() {
      //   this.$bus.$emit('atob', Math.random() * 999)
      bus.$emit('atob', Math.random() * 999)
      this.$parent.str123 = Math.random() * 999
      console.log(this.$parent)
    }
  }
}
</script>
<style lang="scss" scoped>
.sona {
  width: 200px;
  height: 100px;
  background-color: #f00;
}
</style>
